package com.wisnews.service.sr.Impl;

import com.baomidou.mybatisplus.core.conditions.Wrapper;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.wisnews.pojo.sr.entity.Member;
import com.wisnews.mapper.sr.MemberMapper;
import com.wisnews.service.sr.IMemberService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author yuyd
 * @since 2021-02-02
 */
@Service
public class MemberServiceImpl extends ServiceImpl<MemberMapper, Member> implements IMemberService {

    @Autowired
    private MemberMapper memberMapper;


    /**
     * @description: 根据分页条件，和查询条件返回用户列表
     * @param: topage 分页条件 req 查询条件
     * @return: 查询数据
     * @author yuyd
     * @date: 2021/3/31 17:18
     */
    @Override
    public IPage<Member> getListForInput(IPage<Member> toPage, Member req) {
        Wrapper<Member> wrapper = Wrappers.lambdaQuery();
        return  memberMapper.getMemberList(wrapper,toPage);
    }
}
